package com.boyuan.huijiaoyu;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.TextView;

public class PersonSettingActivity extends Activity implements OnClickListener {

	private TextView mTxt_title;
	private String backtitle;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_person_setting);
		initUI();
	}

	private void initUI() {
		Intent intent = getIntent();
		backtitle = intent.getStringExtra("backtitle");
		TextView tvback = (TextView) findViewById(R.id.tv_myback);
		tvback.setText(backtitle);
		findViewById(R.id.lay_mima).setOnClickListener(this);
		findViewById(R.id.myback).setOnClickListener(this);
		findViewById(R.id.lay_guanyu).setOnClickListener(this);
		mTxt_title = (TextView) findViewById(R.id.txt_title);
		mTxt_title.setText("设置");
	}


	@Override
	public void onClick(View v) {
		switch (v.getId()) {
		case R.id.lay_mima:
			Intent intent = new Intent(this, AboutWeiTownActivity.class);
			intent.putExtra("titleback", mTxt_title.getText().toString().trim());
			startActivity(intent);
			break;
		case R.id.myback:
			finish();
			break;
		case R.id.lay_guanyu:
			Intent intent2 = new Intent(this, AboutHuijiaoyuActivity.class);
			intent2.putExtra("titleback", mTxt_title.getText().toString().trim());
			startActivity(intent2);
			break;
		default:
			break;
		}
	}

}
